﻿Imports System.Windows.Forms

Public Class frmSelectByPoly

    Private Sub OK_Button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnOK.Click
        Me.DialogResult = System.Windows.Forms.DialogResult.OK
        Me.Close()
    End Sub

    Private Sub Cancel_Button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCancel.Click
        Me.DialogResult = System.Windows.Forms.DialogResult.Cancel
        Me.Close()
    End Sub

    Private Sub frmVoggRect_FormClosed(sender As Object, e As System.Windows.Forms.FormClosedEventArgs) Handles Me.FormClosed
        SaveSetting(REGAPP, Me.Name, "PolyLayer", cboPolygonLayer.Text)
    End Sub

    Private Sub frmVoggRect_Load(sender As Object, e As System.EventArgs) Handles Me.Load
        cboPolygonLayer.Text = GetSetting(REGAPP, Me.Name, "PolyLayer", "")
        If cboPolygonLayer.SelectedIndex = -1 AndAlso cboPolygonLayer.Items.Count > 0 Then cboPolygonLayer.SelectedIndex = 0
    End Sub

End Class
